#define DEBUG
#include <cstdio>
#include <cmath>

using namespace std;

int min(int a, int b) {
  return a<b ? a : b;
}

int max(int a, int b) {
  return a>b ? a : b;
}

int dis(int a[], int b[]) {
  return abs(a[0]-b[0])+abs(a[1]-b[1]);
}

const int maxn=100000, inf=0x7ffffff;

int main() {
#ifdef DEBUG
  freopen("2.in", "r", stdin);
  freopen("2.out", "w", stdout);
#endif

  static int point[maxn+1][2];
  int n;
  scanf("%d", &n);
  for (int i=1; i<=n; i++) {
    scanf("%d %d", point[i], point[i]+1);
  }

  int ansmin=inf, ansmax=0;
  for (int i=1; i<=n; i++) {
    for (int j=i+1; j<=n; j++) {
      for (int k=j+1; k<=n; k++) {
	int t=dis(point[i], point[j])+dis(point[j], point[k])+dis(point[k],point[i]);
	ansmin = min(ansmin, t), ansmax = max(ansmax, t);
      }
    }
  }

  printf("%d\n%d\n", ansmax, ansmin);

  fclose(stdin);
  fclose(stdout);
  return 0;
}
